package com.ldx.eduline.college.controller;

import com.ldx.eduline.common.bean.R;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/user")
public class EduLoginController {

    @PostMapping("/login")
    private R login(){
        return R.success().addData("token","admin");
    }

    @GetMapping("/info")
    public R info(){
        return R.success().addData("roles","[admin]")
                .addData("name","admin")
                .addData("avatar","http://localhost:8081/tly.jpg");
    }

}
